import javax.xml.crypto.dsig.spec.XSLTTransformParameterSpec;
import java.time.format.SignStyle;
import java.util.Scanner;

public class test {
    public static void main(String[] args) {
//        Scanner scanner=new Scanner(System.in);
//        int n=scanner.nextInt();
//        System.out.println(n);
//
//        float f=scanner.nextFloat();
//        System.out.println(f);
//        Scanner scanner=new Scanner(System.in);
//        int n=scanner.nextInt();
//        System.out.println(n);
//        float f=scanner.nextFloat();
//        System.out.println(f);

        Scanner scanner=new Scanner(System.in);
        System.out.println("请输入你的名字");
        String str=scanner.nextLine();
        System.out.println(str);


    }

    public static void main35(String[] args) {
        int sum=0;
        for (int i = 1; i < 6; i++) {
            int j=1;
            int ret=1;
            for (j = 1; j <= i; j++) {
                ret*=j;
            }
            sum+=ret;
        }

        System.out.println(sum);
    }
    public static void main34(String[] args) {
        for (int i = 0; i < 10; i++) {
            System.out.println(i);
        }
        int a=10;
        System.out.println(a);
    }

    public static void main33(String[] args) {
        int i=1;
        while(i<=100){
            if(i%15!=0){
                i++;
                continue;
            }
            System.out.println(i);
            i++;
        }
    }

    public static void main32(String[] args) {
        int i=1;
        int sum=0;
        while(i<=5){
            int j=1;
            int ret=1;
            while(j<=i){
                ret*=j;
                j++;
            }
            i++;
            sum+=ret;
        }
        System.out.println(sum);
    }

    public static void main31(String[] args) {
        int sum=0;
        int i=1;
        while(i<=5){
            int j=1;
            int ret=1;
            while(j<=i){
                ret*=j;
                j++;
            }
            i++;
            sum+=ret;
        }
        System.out.println(sum);
    }

    public static void main30(String[] args) {
        int n=1;
        int ret=1;
        while(n<=5){
            ret*=n;
            n++;
        }
        System.out.println(ret);
    }

    public static void main29(String[] args) {
        int sum=0;
        int n=1;
        while(n<=100){
            sum+=n;
            n++;
        }
        System.out.println(sum);
    }

    public static void main28(String[] args) {
        int a=1;
        while(a<=10){
            System.out.print(a+" ");//不加ln，则不换行
            a++;
        }
    }

    public static void main27(String[] args) {
        String a="hello";
        switch (a){
            case "true":
                System.out.println(1);
                break;
            case "false":
                System.out.println(2);
                break;
            default:
                System.out.println("hhh");
                break;
        }

//        long boolean float double 不能作为switch类型的参数
//          switch类型的参数不能是复杂的表达式
//        boolean  a=true;
//        switch (a){
//            case true:
//                System.out.println(1);
//                break;
//            case false:
//                System.out.println(2);
//                break;
//            default:
//                System.out.println("hhh");
//                break;
//        }
//        int  a=1;
//        switch (a){
//            case 1:
//                System.out.println(1);
//                break;
//            case 2:
//                System.out.println(2);
//                break;
//            case 3:
//                System.out.println(3);
//                break;
//            default:
//                System.out.println("hhh");
//                break;
//        }
    }
    public static void main26(String[] args) {
        int year=2000;
        if(year%100==0){
            if(year%400==0){
                System.out.println("是闰年");
            }else{
                System.out.println("不是闰年");
            }
        }else{
            if(year%4==0){
                System.out.println("是闰年");
            }else{
                System.out.println("不是闰年");
            }
        }
    }

    public static void main25(String[] args) {
        int a=10;
        if(a>0){
            System.out.println(a+"是正数");
        }else if(a<0){
            System.out.println("负数");
        }else{
            System.out.println("0");
        }
    }

    public static void main24(String[] args) {
        int a=11;
        if(a%2==0){
            System.out.println("偶数");
        }else{
            System.out.println("奇数");
        }
    }

    public static void main23(String[] args) {
        boolean a=false;
        if(a){
            System.out.println("aaa");
        }
        else{
            System.out.println("bbb");
        }
    }
    public static void main22(String[] args) {
        System.out.println("aaa");
        System.out.println("bbb");
        System.out.println("ccc");
        System.out.println("ddd");
    }

    public static void main21(String[] args) {
        boolean flg=true==true?(true==false?false:true):false;
        System.out.println(flg);
    }

    public static void main20(String[] args) {
        int a=11;
        int b=a<<1;
        System.out.println(b);
//        a<<=1;
//        System.out.println(a);

        int c=a<<1;
        System.out.println(c);

        int d=a>>1;
        System.out.println(d);

        int e=-1;
        System.out.println(e>>>1);
    }

    public static void main19(String[] args) {
        int a=10;
        a++;
        System.out.println(a);
        a--;
        System.out.println(a);
        int b=20;
        System.out.println(a==b);

        int c=3;
        int d=4;
        System.out.println(c>d&&c==3);
        System.out.println(c<d&&c==3);
        System.out.println(c<d||c==3);

        //短路与，当表达式1为假的时候，则不会执行表达式2
        System.out.println(c>d&&10%0==0);

        //短路或
        System.out.println(c<d||10%0==0);

        System.out.println(!true);
        System.out.println(!false);
    }
    public static void main18(String[] args) {
        int c =10;
        long d=20L;
        c+=d;//帮你进行转换
        System.out.println(c);
    }

    public static void main17(String[] args) {
        System.out.println(10%3);
        System.out.println(-10%3);
        //可以对小数求余数
        System.out.println(11.5%2.0);

        //两侧操作数类型不一致时，向类型大的提升
        System.out.println(1+0.2);
    }

    public static void main16(String[] args) {
        System.out.println(5/2);
        System.out.println(5/1);
    }

    //把字符串转为整数
    public static void main15(String[] args) {
        String str1="123";

        int a=Integer.valueOf(str1);
        System.out.println(a+1);

        int b=Integer.parseInt(str1);
        System.out.println(b+2  );

    }





    //把整数转成字符串
    public static void main14(String[] args) {
        int a=123;
        String str1=a+"";
        System.out.println(str1);
        System.out.println("==========");
        String str2=String.valueOf(a);
        System.out.println(str2);
        String str3=String.valueOf(a);
        System.out.println(str3);
    }

    public static void main13(String[] args) {
        int a=10;
        System.out.println(a);
        System.out.println("a=="+a);
        System.out.printf("a=%d\n",a);
        int b=20;
        //单纯的拼接
        System.out.println("a="+a+b);
        System.out.println("a="+(a+b));

        //第一个加号是求和，第二个加号是拼接
        System.out.println(a+b+"=a+b");

    }

    public static void main12(String[] args) {


//        System.out.println(s1);
        //拼接
        String s1="hello";
        String s2=" word!";
        System.out.println(s1+s2);
        //求字符串长度
        System.out.println(s1.length());
        System.out.println(s2.length());

        //具体获取某个字符
        System.out.println(s1.charAt(0));
        System.out.println(s2.charAt(2));
    }

    public static void main11(String[] args) {
        byte a=10;
        byte b=30;
        //byte占两个字节，对于小于4个字节的数据，在计算时，
        // 首先会提升到4个字节，然后再进行计算，那么得到的数据类型也就是int类型
        int c=a+b;
        System.out.println(c);
    }

    public static void main10(String[] args) {
        int a=10;
        long b=30;

        //a 是int类型，b是long类型，计算的时候，a会提升为long类型，
        // 然后进行long类型和long类型的计算，然后得到c也是long类型
        long c=a+b;
        System.out.println(c);
    }

    public static void main9(String[] args) {
        int a=10;
        long b=100L;
//        b=a;
//        a=b;
        a=(int)b;
        System.out.println(a);
        System.out.println(b);
    }

    public static void main8(String[] args) {
        //没有明确的的指明是多少字节
        boolean b=true;
        System.out.println(b);
        Boolean a=false;
        System.out.println(a);
    }

    public static void main7(String[] args) {
//        char 是两个字节，可以存储汉字  unicode
        char a='a';
        char b='高';
        System.out.println(a);
        System.out.println(b);
        Character c='哈';
        System.out.println(c);
        System.out.println(Character.MAX_VALUE);
        System.out.println(Character.MIN_VALUE);
    }

    public static void main6(String[] args) {

        double a=1;
        double b=2;
        System.out.println(a/b);

        double num=1.1;
        System.out.println(num*num);

        System.out.println(Double.MAX_VALUE);
        System.out.println(Double.MIN_VALUE);


        float f=12.5f;
        System.out.println(f);
        System.out.println(Float.MAX_VALUE);
        System.out.println(Float.MIN_VALUE);
    }


    public static void main5(String[] args) {
        byte a=20;
        System.out.println(a);

        System.out.println(Byte.MAX_VALUE);
        System.out.println(Byte.MIN_VALUE);
    }


    public static void main4(String[] args) {
        short a=10;
        System.out.println(a);


        System.out.println(Short.MAX_VALUE);
        System.out.println(Short.MIN_VALUE);
    }


    public static void main3(String[] args) {
        long a=20;
        System.out.println(a);
        System.out.println(Long.MAX_VALUE);
        System.out.println(Long.MIN_VALUE);
    }


    public static void main1(String[] args) {
        int a=20;
        System.out.println(a);

        System.out.println(Integer.MAX_VALUE);
        System.out.println(Integer.MIN_VALUE);

        Integer b=1000;
        System.out.println(b);
    }

    public static void main2(String[] args) {
        System.out.println("Hello world!");

        System.out.println(10);

        final int a=9;

        System.out.println(a);
        System.out.println('A');
        System.out.println(true);
        System.out.println(false);
    }

}
